package vno.fux.res.pool
{
	import com.mosesSupposes.bitmap.InteractivePNG;
	import flash.display.Bitmap;
	import flash.display.BitmapData;
	import flash.events.Event;
	
	public class PNGAttacher extends InteractivePNG implements IResourceAttacher
	{
		private var _bitmap:Bitmap;
		public function PNGAttacher()
		{
			super();
			_bitmap = new Bitmap;
			this.addChild(_bitmap);
		}
		
		public function recieve(resource:Object):void
		{
			_bitmap.bitmapData = resource as BitmapData;
			this.drawBitmapHitArea();
			dispatchEvent(new Event(ResourceAttacher.RECIEVE));
		}
	}
}